package com.example.chatserver;

import java.net.SocketAddress;

public interface OnReceive {

	void onReceive(ReceiveData data);

	void error(Exception ex);

	public class ReceiveData {

		public ReceiveData() {
			super();
		}

		public ReceiveData(SocketAddress fromAddress, int port, byte[] data) {
			super();
			this.fromAddress = fromAddress;
			this.port = port;
			this.data = data;
		}

		public SocketAddress fromAddress;

		public int port;

		public byte[] data;
	}
}
